home *** CD-ROM | disk | FTP | other *** search
/ Cre@te Online 2000 December / Cre@teOnline CD05.iso / MacSoft / XML ConsoleMax.sea / XML ConsoleMax / Required / xml4j.jar / com / ibm / xml / xpointer / XPointerParser.class (.txt) < prev   
Encoding:
Java Class File  |  1999-08-30  |  9.7 KB  |  619 lines

  1. package com.ibm.xml.xpointer;
  2.  
  3. import com.ibm.xml.parser.XMLChar;
  4. import java.util.Hashtable;
  5. import java.util.Vector;
  6.  
  7. public class XPointerParser {
  8.    static Hashtable s_keys = new Hashtable(14);
  9.    String xpointer;
  10.    int index;
  11.  
  12.    public XPointer parse(String var1) throws XPointerParseException {
  13.       return this.parse(var1, 0);
  14.    }
  15.  
  16.    public XPointer parse(String var1, int var2) throws XPointerParseException {
  17.       AbsTerm var3 = null;
  18.       Vector var4 = new Vector();
  19.       this.xpointer = var1;
  20.       this.index = var2;
  21.       byte var5 = 0;
  22.       boolean var6 = false;
  23.  
  24.       while(this.index < this.xpointer.length() && !var6) {
  25.          switch (var5) {
  26.             case 0:
  27.                String var14 = this.getName();
  28.                if (var14 == null) {
  29.                   throw new XPointerParseException("Syntax error: [ROOT] Expect a name.");
  30.                }
  31.  
  32.                Integer var15 = (Integer)s_keys.get(var14);
  33.                if (var15 == null) {
  34.                   String var17 = "Syntax error: [ROOT] Unexpected name: " + var14;
  35.                   throw new XPointerParseException(var17);
  36.                }
  37.  
  38.                switch (var15) {
  39.                   case 1:
  40.                   case 2:
  41.                   case 3:
  42.                   case 4:
  43.                      var3 = this.parseAbsTerm(var15);
  44.                      break;
  45.                   case 5:
  46.                   case 6:
  47.                   case 7:
  48.                   case 8:
  49.                   case 9:
  50.                   case 10:
  51.                   case 11:
  52.                   case 12:
  53.                   case 13:
  54.                   case 14:
  55.                      var4.addElement(this.parseOtherTerm(var15, var14));
  56.                      break;
  57.                   default:
  58.                      var6 = true;
  59.                      throw new XPointerParseException("Internal Error: [ROOT]");
  60.                }
  61.  
  62.                var5 = 1;
  63.                break;
  64.             case 1:
  65.                if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 46) {
  66.                   var6 = true;
  67.                } else {
  68.                   if (this.index < this.xpointer.length()) {
  69.                      this.xpointer.charAt(this.index++);
  70.                   }
  71.  
  72.                   if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 40) {
  73.                      var4.addElement(this.parseOtherTerm(-1, (String)null));
  74.                   } else {
  75.                      String var7 = this.getName();
  76.                      if (var7 == null) {
  77.                         throw new XPointerParseException("Syntax error: [ROOT] Expect a name.");
  78.                      }
  79.  
  80.                      Integer var8 = (Integer)s_keys.get(var7);
  81.                      if (var8 == null) {
  82.                         String var16 = "Syntax error: [ROOT] Unexpected name: " + var7;
  83.                         throw new XPointerParseException(var16);
  84.                      }
  85.  
  86.                      switch (var8) {
  87.                         case 1:
  88.                         case 2:
  89.                         case 3:
  90.                         case 4:
  91.                            var6 = true;
  92.                            String var9 = "Syntax error: [ROOT] Unexpected name: " + var7;
  93.                            throw new XPointerParseException(var9);
  94.                         case 5:
  95.                         case 6:
  96.                         case 7:
  97.                         case 8:
  98.                         case 9:
  99.                         case 10:
  100.                         case 11:
  101.                         case 12:
  102.                         case 13:
  103.                         case 14:
  104.                            var4.addElement(this.parseOtherTerm(var8, var7));
  105.                            break;
  106.                         default:
  107.                            var6 = true;
  108.                            throw new XPointerParseException("Internal Error: [ROOT]");
  109.                      }
  110.                   }
  111.                }
  112.                break;
  113.             default:
  114.                var6 = true;
  115.                String var18 = "Internal Error: [ROOT] Invalid state: " + var5;
  116.                throw new XPointerParseException(var18);
  117.          }
  118.       }
  119.  
  120.       this.xpointer = this.xpointer.substring(var2, this.index);
  121.       return new XPointer(var3, var4);
  122.    }
  123.  
  124.    public String toString() {
  125.       return this.xpointer;
  126.    }
  127.  
  128.    public static void main(String[] var0) {
  129.       if (var0.length != 1) {
  130.          System.err.println("Require 1 argument.");
  131.          System.exit(1);
  132.       }
  133.  
  134.       try {
  135.          XPointer var1 = (new XPointerParser()).parse(var0[0]);
  136.          System.out.println("PARSED and RESTRUCTED: " + var1.toString());
  137.       } catch (XPointerParseException var2) {
  138.          ((Throwable)var2).printStackTrace();
  139.       }
  140.    }
  141.  
  142.    AbsTerm parseAbsTerm(int var1) throws XPointerParseException {
  143.       String var2 = null;
  144.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 40) {
  145.          String var5 = "Syntax error: expect `(': " + this.left();
  146.          throw new XPointerParseException(var5);
  147.       } else {
  148.          if (this.index < this.xpointer.length()) {
  149.             this.xpointer.charAt(this.index++);
  150.          }
  151.  
  152.          if (var1 == 3) {
  153.             String var3 = this.getName();
  154.             if (var3 == null) {
  155.                String var4 = "Syntax error: expect ID name: " + this.left();
  156.                throw new XPointerParseException(var4);
  157.             }
  158.  
  159.             var2 = var3;
  160.          } else if (var1 == 4) {
  161.             var2 = this.getSkipLit();
  162.          }
  163.  
  164.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41) {
  165.             throw new XPointerParseException("Syntax error: expect `)'");
  166.          } else {
  167.             if (this.index < this.xpointer.length()) {
  168.                this.xpointer.charAt(this.index++);
  169.             }
  170.  
  171.             return new AbsTerm(var1, var2);
  172.          }
  173.       }
  174.    }
  175.  
  176.    RelTerm parseRelTerm(int var1) throws XPointerParseException {
  177.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 40) {
  178.          String var9 = "Syntax error: expect `(': " + this.left();
  179.          throw new XPointerParseException(var9);
  180.       } else {
  181.          boolean var2 = false;
  182.          int var3 = -1;
  183.          String var4 = null;
  184.          byte var5 = 0;
  185.          Vector var6 = new Vector();
  186.          if (this.index < this.xpointer.length()) {
  187.             this.xpointer.charAt(this.index++);
  188.          }
  189.  
  190.          String var7 = this.getName();
  191.          if (var7 != null && "all".equals(var7)) {
  192.             var2 = true;
  193.          } else {
  194.             if (var7 != null) {
  195.                String var8 = "Syntax error: [relterm] expect a name or number: " + var7;
  196.                throw new XPointerParseException(var8);
  197.             }
  198.  
  199.             var3 = this.getDigit();
  200.          }
  201.  
  202.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 44) {
  203.             if (this.index < this.xpointer.length()) {
  204.                this.xpointer.charAt(this.index++);
  205.             }
  206.  
  207.             if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 35) {
  208.                if (this.index < this.xpointer.length()) {
  209.                   this.xpointer.charAt(this.index++);
  210.                }
  211.  
  212.                var7 = this.getName();
  213.                if (var7 != null) {
  214.                   if (var7.equals("element")) {
  215.                      var5 = 2;
  216.                   } else if (var7.equals("pi")) {
  217.                      var5 = 3;
  218.                   } else if (var7.equals("comment")) {
  219.                      var5 = 4;
  220.                   } else if (var7.equals("text")) {
  221.                      var5 = 5;
  222.                   } else if (var7.equals("cdata")) {
  223.                      var5 = 6;
  224.                   } else if (var7.equals("all")) {
  225.                      var5 = 7;
  226.                   }
  227.                }
  228.             } else {
  229.                var4 = this.getName();
  230.                var5 = 1;
  231.             }
  232.  
  233.             if (var5 == 0) {
  234.                String var11 = "Syntax error: [relterm] expect a name/#element/#pi/#comment/#text/#cdata/#all: #" + var7;
  235.                throw new XPointerParseException(var11);
  236.             }
  237.  
  238.             while(this.index < this.xpointer.length() && (this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41 && (this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 44) {
  239.                var6.addElement(this.parseAttribute());
  240.             }
  241.          }
  242.  
  243.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41) {
  244.             String var10 = "Syntax error: [relterm] expect `)': " + this.left();
  245.             throw new XPointerParseException(var10);
  246.          } else {
  247.             if (this.index < this.xpointer.length()) {
  248.                this.xpointer.charAt(this.index++);
  249.             }
  250.  
  251.             return new RelTerm(var1, var2, var3, var5, var4, var6);
  252.          }
  253.       }
  254.    }
  255.  
  256.    RelTermAttribute parseAttribute() throws XPointerParseException {
  257.       byte var2 = -1;
  258.       Object var3 = null;
  259.       if (this.index < this.xpointer.length()) {
  260.          this.xpointer.charAt(this.index++);
  261.       }
  262.  
  263.       String var1;
  264.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 42) {
  265.          var1 = "*";
  266.          if (this.index < this.xpointer.length()) {
  267.             this.xpointer.charAt(this.index++);
  268.          }
  269.       } else {
  270.          var1 = this.getName();
  271.          if (var1 == null) {
  272.             String var10 = "Syntax error: expect `*' or Name: " + this.left();
  273.             throw new XPointerParseException(var10);
  274.          }
  275.       }
  276.  
  277.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 44) {
  278.          String var9 = "Syntax error: expect `,': " + this.left();
  279.          throw new XPointerParseException(var9);
  280.       } else {
  281.          if (this.index < this.xpointer.length()) {
  282.             this.xpointer.charAt(this.index++);
  283.          }
  284.  
  285.          String var7;
  286.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 42) {
  287.             if (this.index < this.xpointer.length()) {
  288.                this.xpointer.charAt(this.index++);
  289.             }
  290.  
  291.             var2 = 1;
  292.             var7 = "*";
  293.          } else if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 35) {
  294.             if (this.index < this.xpointer.length()) {
  295.                this.xpointer.charAt(this.index++);
  296.             }
  297.  
  298.             String var4 = this.getName();
  299.             if (var4 == null || !"IMPLIED".equals(var4)) {
  300.                String var5 = "Syntax error: [relterm] expect `#IMPLIED': " + this.left();
  301.                throw new XPointerParseException(var5);
  302.             }
  303.  
  304.             var2 = 0;
  305.             var7 = "#IMPLIED";
  306.          } else if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 34 && (this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 39) {
  307.             var2 = 2;
  308.             var7 = this.getName();
  309.             if (var7 == null) {
  310.                String var8 = "Syntax error: [relterm] expect a name: " + this.left();
  311.                throw new XPointerParseException(var8);
  312.             }
  313.          } else {
  314.             var2 = 3;
  315.             var7 = this.getSkipLit();
  316.          }
  317.  
  318.          return new RelTermAttribute(var1, var2, var7);
  319.       }
  320.    }
  321.  
  322.    StringTerm parseStringTerm() throws XPointerParseException {
  323.       boolean var1 = false;
  324.       int var2 = -1;
  325.       Object var3 = null;
  326.       boolean var4 = false;
  327.       boolean var5 = false;
  328.       int var6 = -1;
  329.       int var7 = -1;
  330.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 40) {
  331.          String var12 = "Syntax error: [string] expect `(': " + this.left();
  332.          throw new XPointerParseException(var12);
  333.       } else {
  334.          if (this.index < this.xpointer.length()) {
  335.             this.xpointer.charAt(this.index++);
  336.          }
  337.  
  338.          String var8 = this.getName();
  339.          if (var8.equals("all")) {
  340.             var1 = true;
  341.          } else {
  342.             var2 = this.getDigit();
  343.          }
  344.  
  345.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 44) {
  346.             String var13 = "Syntax error: [string] expect `,':" + this.left();
  347.             throw new XPointerParseException(var13);
  348.          } else {
  349.             if (this.index < this.xpointer.length()) {
  350.                this.xpointer.charAt(this.index++);
  351.             }
  352.  
  353.             String var10 = this.getSkipLit();
  354.             if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 44) {
  355.                if (this.index < this.xpointer.length()) {
  356.                   this.xpointer.charAt(this.index++);
  357.                }
  358.  
  359.                var4 = true;
  360.                var8 = this.getName();
  361.                if (var8.equals("end")) {
  362.                   var5 = true;
  363.                } else {
  364.                   var6 = this.getDigit();
  365.                }
  366.  
  367.                if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) == 44) {
  368.                   if (this.index < this.xpointer.length()) {
  369.                      this.xpointer.charAt(this.index++);
  370.                   }
  371.  
  372.                   var7 = this.getNaturalNumber();
  373.                }
  374.             }
  375.  
  376.             if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41) {
  377.                String var9 = "Syntax error: [string] expect `)':" + this.left();
  378.                throw new XPointerParseException(var9);
  379.             } else {
  380.                if (this.index < this.xpointer.length()) {
  381.                   this.xpointer.charAt(this.index++);
  382.                }
  383.  
  384.                return new StringTerm(var1, var2, var10, var4, var5, var6, var7);
  385.             }
  386.          }
  387.       }
  388.    }
  389.  
  390.    AttrTerm parseAttrTerm() throws XPointerParseException {
  391.       Object var1 = null;
  392.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 40) {
  393.          String var5 = "Syntax error: [attr] expect `(': " + this.left();
  394.          throw new XPointerParseException(var5);
  395.       } else {
  396.          if (this.index < this.xpointer.length()) {
  397.             this.xpointer.charAt(this.index++);
  398.          }
  399.  
  400.          String var3 = this.getName();
  401.          if (var3 == null) {
  402.             String var4 = "Syntax error: [attr] expect a name: " + this.left();
  403.             throw new XPointerParseException(var4);
  404.          } else if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41) {
  405.             String var2 = "Syntax error: [attr] expect `)': " + this.left();
  406.             throw new XPointerParseException(var2);
  407.          } else {
  408.             if (this.index < this.xpointer.length()) {
  409.                this.xpointer.charAt(this.index++);
  410.             }
  411.  
  412.             return new AttrTerm(var3);
  413.          }
  414.       }
  415.    }
  416.  
  417.    SpanTerm parseSpanTerm() throws XPointerParseException {
  418.       Object var1 = null;
  419.       Object var2 = null;
  420.       if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 40) {
  421.          String var7 = "Syntax error: [span] expect `(': " + this.left();
  422.          throw new XPointerParseException(var7);
  423.       } else {
  424.          if (this.index < this.xpointer.length()) {
  425.             this.xpointer.charAt(this.index++);
  426.          }
  427.  
  428.          XPointerParser var3 = new XPointerParser();
  429.          XPointer var5 = var3.parse(this.xpointer, this.index);
  430.          this.index += var3.xpointer.length();
  431.          if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 44) {
  432.             String var8 = "Syntax error: [span] expect ',': " + this.left();
  433.             throw new XPointerParseException(var8);
  434.          } else {
  435.             if (this.index < this.xpointer.length()) {
  436.                this.xpointer.charAt(this.index++);
  437.             }
  438.  
  439.             XPointer var6 = var3.parse(this.xpointer, this.index);
  440.             this.index += var3.xpointer.length();
  441.             if ((this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1) != 41) {
  442.                String var4 = "Syntax error: [span] expect ')': " + this.left();
  443.                throw new XPointerParseException(var4);
  444.             } else {
  445.                if (this.index < this.xpointer.length()) {
  446.                   this.xpointer.charAt(this.index++);
  447.                }
  448.  
  449.                return new SpanTerm(var5, var6);
  450.             }
  451.          }
  452.       }
  453.    }
  454.  
  455.    static String makeSkipLit(String var0) {
  456.       return var0.indexOf(34) >= 0 ? "'" + var0 + "'" : "\"" + var0 + "\"";
  457.    }
  458.  
  459.    String left() {
  460.       return this.xpointer.substring(this.index);
  461.    }
  462.  
  463.    private OtherTerm parseOtherTerm(int var1, String var2) throws XPointerParseException {
  464.       Object var3 = null;
  465.       switch (var1) {
  466.          case -1:
  467.          case 5:
  468.          case 6:
  469.          case 7:
  470.          case 8:
  471.          case 9:
  472.          case 10:
  473.          case 11:
  474.             var3 = this.parseRelTerm(var1);
  475.          case 0:
  476.          case 1:
  477.          case 2:
  478.          case 3:
  479.          case 4:
  480.          default:
  481.             break;
  482.          case 12:
  483.             var3 = this.parseSpanTerm();
  484.             break;
  485.          case 13:
  486.             var3 = this.parseAttrTerm();
  487.             break;
  488.          case 14:
  489.             var3 = this.parseStringTerm();
  490.       }
  491.  
  492.       return (OtherTerm)var3;
  493.    }
  494.  
  495.    // $FF: renamed from: in () boolean
  496.    private final boolean method_0() {
  497.       return this.index < this.xpointer.length();
  498.    }
  499.  
  500.    private final int next() {
  501.       return this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1;
  502.    }
  503.  
  504.    private final int get() {
  505.       return this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1;
  506.    }
  507.  
  508.    private void error(String var1) throws XPointerParseException {
  509.       throw new XPointerParseException(var1);
  510.    }
  511.  
  512.    private String getName() {
  513.       int var1 = this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1;
  514.       if (!XMLChar.isLetter((char)var1) && var1 != 95 && var1 != 58) {
  515.          return null;
  516.       } else {
  517.          StringBuffer var2 = new StringBuffer(32);
  518.  
  519.          do {
  520.             var2.append((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1));
  521.          } while(this.index < this.xpointer.length() && XMLChar.isNameChar((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1)));
  522.  
  523.          return var2.toString();
  524.       }
  525.    }
  526.  
  527.    private String getSkipLit() throws XPointerParseException {
  528.       StringBuffer var1 = new StringBuffer(32);
  529.       int var2 = this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1;
  530.       if (var2 != 34 && var2 != 39) {
  531.          String var3 = "Syntax error: expect \" or ': " + this.left();
  532.          throw new XPointerParseException(var3);
  533.       } else {
  534.          if (this.index < this.xpointer.length()) {
  535.             this.xpointer.charAt(this.index++);
  536.          }
  537.  
  538.          while(this.index < this.xpointer.length() && var2 != (this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1)) {
  539.             var1.append((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1));
  540.          }
  541.  
  542.          if (this.index >= this.xpointer.length()) {
  543.             throw new XPointerParseException("Unexpected end.");
  544.          } else {
  545.             if (this.index < this.xpointer.length()) {
  546.                this.xpointer.charAt(this.index++);
  547.             }
  548.  
  549.             return var1.toString();
  550.          }
  551.       }
  552.    }
  553.  
  554.    private int getDigit() throws XPointerParseException {
  555.       int var1 = this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1;
  556.       byte var2 = 1;
  557.       if (var1 == 45) {
  558.          var2 = -1;
  559.          if (this.index < this.xpointer.length()) {
  560.             this.xpointer.charAt(this.index++);
  561.          }
  562.       } else if (var1 == 43) {
  563.          var2 = 1;
  564.          if (this.index < this.xpointer.length()) {
  565.             this.xpointer.charAt(this.index++);
  566.          }
  567.       }
  568.  
  569.       int var3 = 0;
  570.       if (this.index < this.xpointer.length()) {
  571.          int var10000 = this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1;
  572.          var1 = var10000;
  573.          if (Character.isDigit((char)var10000)) {
  574.             if (this.index < this.xpointer.length()) {
  575.                this.xpointer.charAt(this.index++);
  576.             }
  577.  
  578.             for(var3 = Character.getNumericValue((char)var1); this.index < this.xpointer.length() && Character.isDigit((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1)); var3 = var3 * 10 + Character.getNumericValue((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1))) {
  579.             }
  580.  
  581.             return var3 * var2;
  582.          }
  583.       }
  584.  
  585.       String var4 = "Syntax error: expect digits: " + this.left();
  586.       throw new XPointerParseException(var4);
  587.    }
  588.  
  589.    private int getNaturalNumber() throws XPointerParseException {
  590.       int var1 = 0;
  591.       if (this.index < this.xpointer.length() && Character.isDigit((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1))) {
  592.          for(var1 = Character.getNumericValue((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1)); this.index < this.xpointer.length() && Character.isDigit((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index) : -1)); var1 = var1 * 10 + Character.getNumericValue((char)(this.index < this.xpointer.length() ? this.xpointer.charAt(this.index++) : -1))) {
  593.          }
  594.  
  595.          return var1;
  596.       } else {
  597.          String var2 = "Syntax error: expect digits: " + this.left();
  598.          throw new XPointerParseException(var2);
  599.       }
  600.    }
  601.  
  602.    static {
  603.       s_keys.put(XPointer.literals[1], new Integer(1));
  604.       s_keys.put(XPointer.literals[2], new Integer(2));
  605.       s_keys.put(XPointer.literals[3], new Integer(3));
  606.       s_keys.put(XPointer.literals[4], new Integer(4));
  607.       s_keys.put(XPointer.literals[5], new Integer(5));
  608.       s_keys.put(XPointer.literals[6], new Integer(6));
  609.       s_keys.put(XPointer.literals[7], new Integer(7));
  610.       s_keys.put(XPointer.literals[8], new Integer(8));
  611.       s_keys.put(XPointer.literals[9], new Integer(9));
  612.       s_keys.put(XPointer.literals[10], new Integer(10));
  613.       s_keys.put(XPointer.literals[11], new Integer(11));
  614.       s_keys.put(XPointer.literals[12], new Integer(12));
  615.       s_keys.put(XPointer.literals[13], new Integer(13));
  616.       s_keys.put(XPointer.literals[14], new Integer(14));
  617.    }
  618. }
  619.